/* 基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    background-color: #f4f4f4;
}

.container {
    width: 90%;
    margin: 0 auto;
    padding: 15px;
}

header {
    background: #333;
    color: #fff;
    padding: 1rem;
    margin-bottom: 20px;
}

footer {
    text-align: center;
    padding: 1rem;
    background: #333;
    color: #fff;
    position: fixed;
    bottom: 0;
    width: 100%;
    left: 0;
}

/* 按钮样式 */
.btn {
    padding: 8px 15px;
    border-radius: 4px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: #3498db;
    color: #fff;
}

.btn-danger {
    background: #e74c3c;
    color: #fff;
}

/* 表格样式 */
.data-table {
    background: #fff;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    overflow-x: auto;
}

.data-table table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.data-table th {
    background: #f8f9fa;
    font-weight: 600;
}

/* 搜索栏样式 */
.search-bar {
    margin-bottom: 20px;
}

.search-bar form {
    display: flex;
    gap: 10px;
}

.search-bar input {
    flex: 1;
    padding: 8px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.search-bar button {
    padding: 8px 15px;
    background: #3498db;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

/* 分页样式 */
.pagination {
    display: flex;
    justify-content: center;
    gap: 5px;
    margin-top: 20px;
}

.pagination a {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    color: #333;
    text-decoration: none;
    transition: all 0.3s;
}

.pagination a:hover {
    background: #f5f5f5;
}

.pagination a.active {
    background: #007bff;
    color: white;
    border-color: #007bff;
}

/* 徽章样式 */
.badge {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
}

.badge-primary { background: #3498db; color: #fff; }
.badge-secondary { background: #95a5a6; color: #fff; }
.badge-success { background: #2ecc71; color: #fff; }
.badge-danger { background: #e74c3c; color: #fff; }

/* 图标按钮 */
.btn-icon {
    padding: 5px;
    color: #666;
    text-decoration: none;
}

.btn-icon:hover {
    color: #333;
}

/* 小头像 */
.avatar-small {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

/* 表单样式 */
.form-container {
    background: #fff;
    padding: 20px;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    max-width: 800px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}

.form-group input[type="text"],
.form-group input[type="password"],
.form-group input[type="email"],
.form-group select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.form-group input[type="file"] {
    padding: 8px 0;
}

.required {
    color: #e74c3c;
    margin-left: 3px;
}


.alert {
    padding: 12px 15px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.alert-danger {
    background: #ffeaea;
    color: #e74c3c;
    border: 1px solid #ffd0d0;
}

.alert-success {
    background: #e8f8f5;
    color: #27ae60;
    border: 1px solid #d1f2eb;
}

/* 按钮样式补充 */
.btn-secondary {
    background: #95a5a6;
    color: #fff;
}

.btn-secondary:hover {
    background: #7f8c8d;
}

/* 搜索表单样式补充 */
.search-form {
    display: flex;
    gap: 10px;
}

.select-filter {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
}

/* 评分样式 */
.rating {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.text-warning {
    color: #f1c40f;
}

/* 表格内的图片大小限制 */
.data-table img {
    max-width: 50px;
    max-height: 50px;
    object-fit: cover;
}

/* 文本域样式 */
.form-group textarea {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    resize: vertical;
    min-height: 100px;
}

/* 数字输入框样式 */
.form-group input[type="number"] {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

/* 表单分组布局 */
.form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.form-col {
    flex: 1;
}

/* 统计卡片网格布局 */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    gap: 15px;
}

.stat-card i {
    font-size: 2.5em;
    color: #3498db;
}

.stat-info h3 {
    margin: 0;
    font-size: 14px;
    color: #666;
}

.stat-info p {
    margin: 5px 0 0;
    font-size: 24px;
    font-weight: bold;
    color: #2c3e50;
}

/* 仪表盘网格布局 */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
}

.dashboard-card {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.dashboard-card h3 {
    margin: 0 0 20px;
    color: #2c3e50;
    font-size: 18px;
}

/* 反馈列表样式 */
.feedback-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.feedback-item {
    padding: 15px;
    border: 1px solid #eee;
    border-radius: 4px;
}

.feedback-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.user-name {
    font-weight: bold;
    color: #2c3e50;
}

.feedback-time {
    color: #7f8c8d;
    font-size: 0.9em;
}

.feedback-content {
    color: #34495e;
    margin-bottom: 10px;
}

/* 状态标签 */
.status-badge {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.9em;
}

.status-0 { background: #f1c40f; color: #fff; }
.status-1 { background: #2ecc71; color: #fff; }
.status-2 { background: #e74c3c; color: #fff; }

/* 子菜单样式优化 */
.submenu {
    display: block;
    background: #243342;
    padding: 5px 0;
}

.has-submenu.active .submenu {
    display: block !important;
}

.has-submenu > a {
    position: relative;
    display: flex !important;
    align-items: center !important;
    padding: 12px 20px !important;
    cursor: pointer;
}

.has-submenu > a i.fa-chevron-down {
    margin-left: auto;
    transition: transform 0.3s ease;
}

.has-submenu.active > a {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.has-submenu.active > a i.fa-chevron-down {
    transform: rotate(180deg);
}

.submenu li a {
    padding: 10px 20px 10px 50px;
    font-size: 14px;
    color: #b8c7ce;
    display: block;
    transition: all 0.3s ease;
}

.submenu li a:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    padding-left: 55px;
}

.submenu li a.active {
    color: #3498db;
    background: rgba(52, 152, 219, 0.1);
}

/* 主菜单项样式优化 */
.sidebar nav ul li a {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    color: #b8c7ce;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    border-left: 3px solid transparent;
}

.sidebar nav ul li a:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    border-left-color: #3498db;
}

.sidebar nav ul li a.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    border-left-color: #3498db;
}

/* 图标样式优化 */
.sidebar nav ul li a i:not(.fa-chevron-down) {
    width: 20px;
    margin-right: 10px;
    text-align: center;
    font-size: 16px;
    color: inherit;
}

/* 动画效果 */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.has-submenu.active .submenu {
    display: block;
    animation: slideDown 0.3s ease;
}

/* 登录页面样式 */
.login-page {
    background: #f4f4f4;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
}

.login-box {
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.login-box h2 {
    text-align: center;
    margin-bottom: 30px;
    color: #2c3e50;
}

.login-form .form-group {
    margin-bottom: 20px;
}

.btn-block {
    width: 100%;
}

/* 仪表盘表格样式格式化 */
.dashboard-card .table-responsive {
    margin: -20px;  /* 抵消父元素的内边距 */
}

.dashboard-card table {
    width: 100%;
    border-collapse: collapse;
}

.dashboard-card th,
.dashboard-card td {
    padding: 12px 20px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.dashboard-card th {
    background: #f8f9fa;
    font-weight: 600;
    color: #2c3e50;
    white-space: nowrap;
}

.dashboard-card tr:last-child td {
    border-bottom: none;
}

.dashboard-card tr:hover td {
    background-color: #f8f9fa;
}

/* 反馈列表样式优化 */
.feedback-list {
    margin: -20px;  /* 抵消父元素的内边距 */
}

.feedback-item {
    padding: 20px;
    border-bottom: 1px solid #eee;
    transition: background-color 0.2s;
}

.feedback-item:last-child {
    border-bottom: none;
}

.feedback-item:hover {
    background-color: #f8f9fa;
}

.feedback-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.user-name {
    font-weight: 600;
    color: #2c3e50;
    display: flex;
    align-items: center;
}

.user-name i {
    margin-right: 5px;
    color: #3498db;
}

.feedback-time {
    color: #95a5a6;
    font-size: 0.9em;
}

.feedback-title {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 8px;
    font-size: 1.1em;
}

.feedback-content {
    color: #34495e;
    line-height: 1.5;
    margin-bottom: 12px;
}

/* 状态标签样式优化 */
.status-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.85em;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.status-0 { 
    background: #fff3cd; 
    color: #856404;
    border: 1px solid #ffeeba;
}

.status-1 { 
    background: #d4edda; 
    color: #155724;
    border: 1px solid #c3e6cb;
}

.status-2 { 
    background: #f8d7da; 
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.status-3 { 
    background: #e2e3e5; 
    color: #383d41;
    border: 1px solid #d6d8db;
}

/* 仪表盘卡片样式优化 */
.dashboard-card {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    overflow: hidden;
}

.dashboard-card h3 {
    margin: 0;
    padding: 20px;
    font-size: 16px;
    color: #2c3e50;
    border-bottom: 1px solid #eee;
    background: #f8f9fa;
}

/* 响应式布局优化 */
@media (max-width: 768px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    
    .dashboard-card th,
    .dashboard-card td {
        padding: 10px 15px;
    }
    
    .feedback-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
    
    .feedback-time {
        font-size: 0.8em;
    }
} 

/* 侧边栏样式优化 */
.wrapper {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 250px;
    background: #2c3e50;
    color: #fff;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.main-content {
    flex: 1;
    margin-left: 250px;
    background: #f4f4f4;
    min-height: 100vh;
}

/* Logo样式 */
.sidebar .logo {
    padding: 20px;
    text-align: center;
    background: #243342;
}

.sidebar .logo h2 {
    margin: 0;
    font-size: 20px;
    color: #fff;
}

/* 导航菜单样式 */
.sidebar nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar nav ul li {
    border-bottom: 1px solid #34495e;
}

.sidebar nav ul li a {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    color: #ecf0f1;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    border-left: 3px solid transparent;
}

.sidebar nav ul li a:hover {
    background: #34495e;
    color: #3498db;
    border-left-color: #3498db;
}

.sidebar nav ul li a.active {
    background: #34495e;
    color: #3498db;
    border-left-color: #3498db;
}

.sidebar nav ul li a i:not(.fa-chevron-down) {
    width: 20px;
    margin-right: 10px;
    text-align: center;
    font-size: 16px;
}

/* 顶部导航栏样式 */
.top-header {
    background: #fff;
    padding: 15px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-left h2 {
    margin: 0;
    font-size: 20px;
    color: #2c3e50;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.header-right span {
    color: #7f8c8d;
}

.logout-btn {
    color: #e74c3c;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 5px;
}

.logout-btn:hover {
    color: #c0392b;
}

/* 内容区域样式 */
.content {
    padding: 30px;
}

/* 响应式布局 */
@media (max-width: 768px) {
    .sidebar {
        width: 200px;
        transform: translateX(-200px);
        transition: transform 0.3s ease;
    }
    
    .sidebar.active {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .top-header {
        padding: 15px;
    }
    
    .content {
        padding: 15px;
    }
}

/* 滚动条样式 */
.sidebar::-webkit-scrollbar {
    width: 5px;
}

.sidebar::-webkit-scrollbar-track {
    background: #243342;
}

.sidebar::-webkit-scrollbar-thumb {
    background: #34495e;
    border-radius: 3px;
}

.sidebar::-webkit-scrollbar-thumb:hover {
    background: #3498db;
}

/* 侧边栏基础样式 */
.sidebar {
    width: 250px;
    background: #2c3e50;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.sidebar .logo {
    padding: 20px;
    text-align: center;
    background: #243342;
}

.sidebar .logo h2 {
    margin: 0;
    font-size: 20px;
    color: #fff;
}

/* 导航菜单样式 */
.sidebar nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar nav ul li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar nav ul li a {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    color: #b8c7ce;
    text-decoration: none;
    transition: all 0.3s ease;
}

.sidebar nav ul li a i {
    width: 20px;
    margin-right: 10px;
    font-size: 16px;
}

.sidebar nav ul li a span {
    flex: 1;
}

.sidebar nav ul li a i.fa-chevron-down {
    width: auto;
    margin-right: 0;
    font-size: 12px;
    transition: transform 0.3s ease;
}

/* 悬停和激活状态 */
.sidebar nav ul li a:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

.sidebar nav ul li a.active {
    color: #fff;
    background: #3498db;
}

/* 子菜单样式 */
.submenu {
    display: block;
    background: #243342;
    padding: 5px 0;
}

.has-submenu.active .submenu {
    display: block !important;
}

.has-submenu > a {
    position: relative;
    display: flex !important;
    align-items: center !important;
    padding: 12px 20px !important;
    cursor: pointer;
}

.has-submenu > a i.fa-chevron-down {
    margin-left: auto;
    transition: transform 0.3s ease;
}

.has-submenu.active > a {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.has-submenu.active > a i.fa-chevron-down {
    transform: rotate(180deg);
}

.submenu li a {
    padding: 10px 20px 10px 50px;
    font-size: 14px;
    color: #b8c7ce;
    display: block;
    transition: all 0.3s ease;
}

.submenu li a:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    padding-left: 55px;
}

.submenu li a.active {
    color: #3498db;
    background: rgba(52, 152, 219, 0.1);
} 

/* 帖子详情页样式 */
.post-detail {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    padding: 20px;
}

.post-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 15px 0;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.post-stats {
    display: flex;
    gap: 15px;
}

.post-stats span {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #666;
}

.post-content {
    margin: 20px 0;
}

.post-image {
    margin-bottom: 20px;
}

.post-image img {
    max-width: 100%;
    border-radius: 4px;
}

.post-text {
    line-height: 1.6;
    color: #333;
}

.post-actions {
    display: flex;
    gap: 10px;
    margin: 20px 0;
}

/* 评论区样式 */
.comments-section {
    margin-top: 30px;
}

.comments-section h3 {
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.comment-item {
    background: #f8f9fa;
    border-radius: 4px;
    padding: 15px;
    margin-bottom: 15px;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.comment-time {
    color: #666;
    font-size: 0.9em;
}

.comment-content {
    line-height: 1.5;
    color: #333;
}

.comment-actions {
    margin-top: 10px;
    text-align: right;
} 